<template>
  <!--增加修改-->
  <div>
    <el-row>
      <el-col :span="22" :offset="1">
        <el-card shadow="always">
          <el-form :label-position="labelPosition" :inline="true" :model="form">
            <el-form-item style="width: 100%">
              <el-divider direction="vertical" style="size:20px"></el-divider>
              <span style="color: #0a0a0d;font-size: 20px;float: left">新增项目</span>
              <el-button type="primary" style="float: right;"><a href="../../system/checkproset.vue"
                                                                 style="color: aliceblue">返回</a>
              </el-button>
              <el-button type="primary" @click="onSubmit" style="float: right;margin-right: 10px">保存</el-button>
            </el-form-item>
            <div align="left">
              <h2 style="color: blue">项目信息</h2>
            </div>
            <el-form-item style="width: 20%" align="left" label="项目编号">
              <el-input v-model="form.id"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%" align="left" label="项目名称">
              <el-input v-model="form.name"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%" align="left" label="成本价(元)">
              <el-input v-model="form.price"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%" align="left" label="零售价(元)">
              <el-input v-model="form.price1"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%" align="left" label="单位">
              <el-input v-model="form.danwei"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%  " align="left" label="项目分类">
              <el-input v-model="form.fenlei"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%" align="left" label="发票类型">
              <el-input v-model="form.leixing"></el-input>
            </el-form-item>
            <el-form-item style="width: 20%" align="left" label="录入时间">
              <el-date-picker type="date" placeholder="选择日期" v-model="form.date1" style="width: 100%;"></el-date-picker>
            </el-form-item>
            <el-form-item style="width: 95%" align="left">
              项目状态:
              <el-radio v-model="form.x" label="1">启用</el-radio>
              <el-radio v-model="form.x" label="0">禁用</el-radio>
            </el-form-item>
          </el-form>
        </el-card>

      </el-col>

    </el-row>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        labelPosition: 'top',
        form: {
          id: '',
          name: '',
          price: '',
          price1: '',
          danwei: '',
          fenlei: '',
          leixing: '',
          date1: '',
          x: ""

        }
      };
    },
    methods: {
      onSubmit() {
        alert("保存")
        console.log('submit!');
      }
    }
  }
</script>

<style scoped>

</style>
